home *** CD-ROM | disk | FTP | other *** search
/ Fritz: All Fritz / All Fritz.zip / All Fritz / FILES / SPREOTUS / 123TECH.LZH / 123PREP.DOC < prev    next >
Text File  |  1984-08-26  |  14KB  |  274 lines

  1.      
  2.      
  3.      123PREP File Formatting Program                          Release 2.2
  4.      ====================================================================
  5.      
  6.      WHAT IT DOES:  123PREP is a compiled basic program designed to
  7.      convert a simple text (ASCII) file of FIXED LENGTH records into
  8.      columns directly usable by the LOTUS 1-2-3 FILE IMPORT NUMBERS
  9.      command. 
  10.      
  11.      WHAT LOTUS LEFT OUT:  Although 1-2-3 is very flexible about reading
  12.      in a text file (using  the FILE IMPORT TEXT command), it normally
  13.      will read each line as one continuous line of text. That means that
  14.      the spreadsheet can only be manipulated using complete lines: 
  15.      sorting, column manipulation, database operations and many other
  16.      useful features of Lotus are out of reach. Numeric fields, despite
  17.      their initial appearance, are considered text, which means that no
  18.      mathematical operations can be performed.  
  19.      
  20.      1-2-3 does provide for importing a column-oriented file with the FILE
  21.      IMPORT NUMBERS command, but that requires all text fields to be
  22.      delimited with quotation marks and all numeric fields to be delimited
  23.      with spaces. Problem is, Lotus doesn't provide a way to insert these
  24.      characters. 
  25.      
  26.      FOR EXAMPLE:  A file list from a bulletin board (a really great use
  27.      for this program) may look like this:
  28.      
  29.      123PREP.EXE  05-27-84 REFORMATS TEXT FILES FOR LOTUS 130644
  30.      123PREP.DOC  05-27-84 DOCFILE FOR 123PREP.EXE        1 5130
  31.      
  32.      What 1-2-3 will give you is normally all stuffed into column A:
  33.      
  34.      "123PREP.EXE  05-27-84 REFORMATS TEXT FILES FOR LOTUS 130644"
  35.      "123PREP.DOC  05-27-84 DOCFILE FOR 123PREP.EXE        1 5130"
  36.      
  37.      What you want for your spreadsheet is a sortable database that you
  38.      can mash around, probably requiring your file records to look like
  39.      this, with column a containing "123prep.exe", and so on:
  40.      
  41.       a..........  b....  c.  d..............................  e f....
  42.      "123PREP.EXE""05-27""84""REFORMATS TEXT FILES FOR LOTUS " 1 30644
  43.      "123PREP.DOC""05-27""84""DOCFILE FOR 123PREP.EXE        " 1  5130
  44.      
  45.      
  46.      That's what 123PREP does:  it allows you to vertically divide your
  47.      file into fields and quickly create a properly formatted input file
  48.      for 1-2-3's IMPORT feature, with numeric values preserved and fields
  49.      correctly split into separate columns. 
  50.      
  51.      Since the file is sliced vertically into fields, records should line
  52.      up vertically. But don't worry about a few lines of junk if most of
  53.      the file is usable -- take what's available and edit the rest in
  54.      LOTUS.  123PREP is pretty forgiving in this respect. 
  55.      
  56.      Page 2
  57.      
  58.      123PREP File Formatting Program
  59.      ====================================================================
  60.      
  61.      PROGRAM LIMITS:  This release supports drives A through D and file
  62.      sizes up to the capacity of your disk drives. The amount of memory
  63.      you have in your PC determines how big a file can be read into LOTUS.
  64.      Records can now be up to about 200 characters wide and split into as
  65.      many as 26 columns.
  66.      
  67.      For best performance, use different drives for your input and output
  68.      files.  A RAM disk makes this program really hum, because of all the
  69.      disk activity implicit in the process (read a record, write a
  70.      record).  
  71.      
  72.      
  73.      HOW TO USE IT:  The program operates in 5 steps:
  74.      
  75.      1. Select a TEXT file from any drive. IRMA.TXT is assumed if you
  76.      don't enter a filename, but you MUST specify a disk drive. Press 
  77.      HOME for help or ESC to exit the program. At all subsequent screens,
  78.      ESC "backs up" to the preceding screen to allow you to restart that
  79.      section. For hard disk users:  path names are not supported.
  80.      
  81.      2. Select a disk drive and a file name to receive your formatted
  82.      output. A disk drive must be specified. 123PREP.PRN is assumed  as a
  83.      default filename if you just press enter. Since the file will only be
  84.      used for a short time, any name will do, but it MUST have .PRN as a
  85.      file type for LOTUS to recognize it from the FILE IMPORT menu.
  86.      
  87.      3. The first five records from your input file are then displayed on
  88.      the screen. Each field you specify will become a separate column when
  89.      you load the finished output file into LOTUS 1-2-3. A line of '^^^'
  90.      (carat) characters is harmless and means that the record selected is
  91.      blank; press PgDn to select another if you want.  
  92.      
  93.      Using the cursor control keys described below (all of which are
  94.      located on the number pad on the right side of your IBM/Compaq
  95.      keyboard), select a sample record to serve as a template and then
  96.      divide the template into fields.  
  97.      
  98.      Press:          Operation:
  99.      ------------    ---------------------------------------------------
  100.      HOME         -- Redisplay the template marking HELP screen 
  101.      ESC          -- Return to the output file selection screen 
  102.      Cursor Right -- Include this character in the current field 
  103.      Cursor Left  -- Back space one character
  104.      PgDn         -- Select the next record as a template 
  105.      PgUp         -- Select the previous record as a template 
  106.      END          -- Restart the template marking screen 
  107.      Grey+        -- Accept the current field and start the next field
  108.      Grey-        -- Back up to the start of the previous field
  109.      RETURN       -- ALL DONE. Proceed to the next screen
  110.      
  111.      Page 3
  112.      
  113.      123PREP File Formatting Program
  114.      ====================================================================
  115.      
  116.      For example, pressing the Cursor Right key (the "6" key on the number
  117.      pad on the right-hand side of your keyboard) moves the cursor to the
  118.      right and adds the current character to the field you're creating at
  119.      the moment. Cursor Left backs up a space and drops that character
  120.      from the current field.
  121.      
  122.      Typically, you'll use PgDn to select  a record, Cursor Right to mark
  123.      off the first field (you'll see small a's appear on the template),
  124.      the Grey+ key to start the next field, and ENTER when you're all
  125.      finished.  If your records contain unneeded columns, assign them to
  126.      separate fields and delete the column during the next step.
  127.      
  128.      4. The next step looks at your template record and checks each field
  129.      to see if it has a numeric value. If so, it is highlighted and will
  130.      be output as a number surrounded by spaces in your file. If not, it
  131.      will be output as text and surrounded with quote marks ("). If you
  132.      may want an apparently numeric field to be treated as text, or vice
  133.      versa, enter the field's letter to toggle it back and forth.  You can
  134.      also exclude a field from your output by pressing either SHIFT key
  135.      and entering its letter.  See ENHANCEMENTS below.
  136.      
  137.      5. Process your files.  Records from your input file are read in,
  138.      processed and written to your output file, one at a time.  Any double
  139.      quote characters found are replaced with single quote characters
  140.      during processing.  If needed, you can append a record number at the
  141.      end of each line to simplify editing in Lotus.  Operation is
  142.      continuous until the last input record is handled.  Then start up
  143.      LOTUS and enter /FIN, select your PRN file and press enter to import
  144.      your new file. 
  145.      
  146.      
  147.      ERROR HANDLING has been addressed as completely as possible, but
  148.      nobody's perfect. These are the errors that are most likely to
  149.      occur in 123PREP and their corresponding error codes from the IBM 
  150.      Basic manual:
  151.      
  152.      53 The drive or filename you specified for input doesn't exist. 
  153.      55 Input and Output files can't have the same name. The program
  154.         reads from one file and writes to a second file.
  155.      61 Your output disk is full. Try another one. 
  156.      64 The filename is invalid. 
  157.      70 Your diskette is write protected.
  158.      71 The disk drive you want isn't ready. 
  159.      76 The drive or filename you specified for input doesn't exist. 
  160.      
  161.      Page 4
  162.      
  163.      123PREP File Formatting Program
  164.      ====================================================================
  165.      
  166.      PROBLEM REPORTING:  For reference and problem reporting (in case you
  167.      see a program related error code), the error screen displays the
  168.      error number that occurred and in which line of my source program the
  169.      error occurred.  Nothing magic:  you can look up the error code in
  170.      your IBM BASIC manual. Please call me at the number shown below if
  171.      you find a program "bug" so I can repair it. If you don't call, it
  172.      won't get fixed and others may have the same problem. I really will
  173.      try to help you.  You can help both of us if you can show me how to
  174.      duplicate the problem and provide the error message reported by the
  175.      program.
  176.      
  177.      
  178.      "ERRORS" IN YOUR FILE:  Two special data errors you should be aware 
  179.      of when you use the Lotus IMPORT function -- 
  180.      
  181.      1.  If your input file contains double quotation marks, Lotus insists
  182.      that a new column has been started, whether you use 123PREP or not.
  183.      Since you often can't control what your input file contains, the
  184.      result is extra columns you don't want.  This release of 123PREP
  185.      arbitrarily deals with the problem by replacing any quote marks found
  186.      in your input file with single quotes (apostrophes) during
  187.      processing. Lotus sees single quotes as just an ordinary text
  188.      character; most often, single quotes preserve the grammatical content
  189.      of your records. 
  190.      
  191.      2.  If you specify a numeric field and an "empty" column occurs, you
  192.      need a "place-marker" so that Lotus doesn't ignore the field. 
  193.      Normally, spaces between numeric fields are ignored during IMPORT. 
  194.      As a result, the line "collapses" toward the left margin, shifting
  195.      all subsequent columns to the left.  This release looks for this
  196.      condition during final processing and writes out zero to keep the
  197.      columns lined up properly.
  198.      
  199.      Your INPUT file is never changed, so don't worry about damaging your
  200.      original file. If either condition does occur, the exit screen will
  201.      indicate it so you're aware that your output file has been modified.
  202.      
  203.      
  204.      See your LOTUS documentation for a fuller discussion of the FILE
  205.      IMPORT NUMBERS command.  LOTUS 1-2-3 is a copyrighted product of
  206.      Lotus Development Corp.
  207.      
  208.      
  209.      DISTRIBUTION:  123PREP.EXE AND ITS DOCUMENTATION MAY BE FREELY COPIED
  210.      AND SHARED WITH OTHER USERS FOR ANY NON-COMMERCIAL PURPOSE, BUT ANY
  211.      COMMERCIAL USE OR PUBLICATION IS PROHIBITED WITHOUT MY WRITTEN
  212.      PERMISSION.  I will gladly supply the compiled program and this
  213.      documentation file.  Send a blank diskette, a return mailing label,
  214.      and return postage in a mailer to the address below.  To ensure that
  215.      I can support you properly if you have problems, I will not
  216.      distribute the source code.
  217.      
  218.      Page 5
  219.      
  220.      123PREP File Formatting Program
  221.      ====================================================================
  222.      
  223.      ENHANCEMENTS IN RELEASE 2.2:  As use of a program spreads, user 
  224.      suggestions surface that either directly or indirectly get plowed
  225.      back into the next release.  For those who called, thanks.  New
  226.      features built into this version of 123PREP include:
  227.      
  228.      1.  Quotation marks included in your INPUT file are automatically
  229.      swapped out for apostrophes.  Lotus uses quote marks to separate
  230.      columns during the FILE IMPORT process.  Similarly, if a numeric
  231.      field evaluates to a zero value, a zero is written out to serve as a
  232.      "place-marker" for Lotus.  Otherwise, Lotus would "collapse" the
  233.      column during IMPORT.  The exit screen will tell you whether either 
  234.      condition occurred so that you know your file content has been
  235.      changed.  (Judy Epstein, Highland Park, Illinois.)
  236.      
  237.      2.  You can now exclude one or more columns from your OUTPUT file
  238.      during final processing to squeeze the "air" out and simplify editing
  239.      in LOTUS. Unneeded columns are selected during the TEXT/NUMERIC
  240.      selection process by using either shift key and the letter that
  241.      specifies the field.  SHIFT-A, for example, tells the program to
  242.      drop column A during final processing.  It toggles, so doing it again
  243.      restores the column.  (Mike Erdmann, Minneapolis, Minnesota.)
  244.      
  245.      3.  Records can now be numbered during output if desired.  No matter
  246.      how you sort things around once you start up Lotus, you can always
  247.      restore the original sequence of the file.  Serves as an automatic
  248.      DATA FILL feature.  (Cheryl Wengroff, Skokie, Illinois.)
  249.      
  250.      4.  Fields I and Q no longer fail to clear the screen during the
  251.      TEXT/NUMERIC selection process.  (Mike Erdmann.)
  252.      
  253.      5.  Two limits were raised.  You can now specify up to 26 fields 
  254.      and handle wider records.  I have processed test records up to about
  255.      200 characters wide; looks ugly, but it seems to work.
  256.      
  257.      6.  A fourth HELP screen has been added to the TEXT/NUMERIC screen to
  258.      explain the expanded options available there.
  259.       
  260.      7.  After you have finished processing, you're now offered a loop
  261.      back to the top of the program to work on another file, instead of
  262.      automatically exiting to DOS.
  263.      
  264.      
  265.          Suggestions are welcome. . . 
  266.      
  267.      ====================================================================
  268.      Jon Sims                                                 123PREP.EXE
  269.      600-C South Boulevard                                    Release 2.2
  270.      Evanston, Illinois                                      May 27, 1984
  271.      Telephone:  (312) 982-7312                        (c) Copyright 1984
  272.      ====================================================================
  273.      
  274.